package com.aptech.forms.tdkhoa;

import com.aptech.beans.Users;
import com.aptech.dao.SaleInvoiceManager;
import com.aptech.dao.UserManager;
import com.aptech.validate.AccountValidator;
import java.math.BigInteger;
import java.security.*;
import java.sql.*;
import java.sql.Timestamp;
import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
import java.util.GregorianCalendar;
import java.util.Vector;
import javax.swing.ImageIcon;
import javax.swing.JOptionPane;
import javax.swing.RowFilter;
import javax.swing.RowSorter;
import javax.swing.event.DocumentEvent;
import javax.swing.event.DocumentListener;
import javax.swing.table.DefaultTableModel;
import javax.swing.table.TableModel;
import javax.swing.table.TableRowSorter;

public class SaleInvoiceList extends javax.swing.JFrame {

    int getID;

    public SaleInvoiceList() {
        initComponents();
        setLocationRelativeTo(null);
        loadData();
    }
    
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jdAccList_InsertUpdate = new javax.swing.JDialog();
        jPanel1 = new javax.swing.JPanel();
        jlblAccList_Email1 = new javax.swing.JLabel();
        cbRole = new javax.swing.JComboBox();
        jlblAccList_Email2 = new javax.swing.JLabel();
        jlblAccList_Email3 = new javax.swing.JLabel();
        jbtAccList_Reset = new javax.swing.JButton();
        jbtAccList_Submit = new javax.swing.JButton();
        jLabel2 = new javax.swing.JLabel();
        jScrollPane1 = new javax.swing.JScrollPane();
        jtbAccountList = new javax.swing.JTable();
        jbtAccountListInsert = new javax.swing.JButton();
        jbtAccountListUpdate = new javax.swing.JButton();
        jLabel1 = new javax.swing.JLabel();
        jtfAccList_Search = new javax.swing.JTextField();
        jlblAccList_Username1 = new javax.swing.JLabel();

        jdAccList_InsertUpdate.setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        jdAccList_InsertUpdate.setResizable(false);

        jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder(null, "Information", javax.swing.border.TitledBorder.DEFAULT_JUSTIFICATION, javax.swing.border.TitledBorder.DEFAULT_POSITION, new java.awt.Font("Segoe UI Light", 1, 14), new java.awt.Color(255, 0, 0))); // NOI18N

        jlblAccList_Email1.setFont(new java.awt.Font("Segoe UI Light", 1, 14)); // NOI18N
        jlblAccList_Email1.setForeground(new java.awt.Color(51, 0, 255));
        jlblAccList_Email1.setText("Mode of Payment");

        cbRole.setFont(new java.awt.Font("Segoe UI Light", 0, 14)); // NOI18N
        cbRole.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "COMP", "UNCOMP", "HALF" }));

        jlblAccList_Email2.setFont(new java.awt.Font("Segoe UI Light", 1, 14)); // NOI18N
        jlblAccList_Email2.setForeground(new java.awt.Color(51, 0, 255));
        jlblAccList_Email2.setText("Sale Invoice ID:");

        jlblAccList_Email3.setFont(new java.awt.Font("Segoe UI Light", 1, 14)); // NOI18N
        jlblAccList_Email3.setForeground(new java.awt.Color(51, 0, 255));

        javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
        jPanel1.setLayout(jPanel1Layout);
        jPanel1Layout.setHorizontalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addGap(36, 36, 36)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(jlblAccList_Email2)
                    .addComponent(jlblAccList_Email1))
                .addGap(35, 35, 35)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(cbRole, javax.swing.GroupLayout.PREFERRED_SIZE, 180, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jlblAccList_Email3))
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        jPanel1Layout.setVerticalGroup(
            jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jPanel1Layout.createSequentialGroup()
                .addGap(5, 5, 5)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jlblAccList_Email2)
                    .addComponent(jlblAccList_Email3))
                .addGap(26, 26, 26)
                .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jlblAccList_Email1)
                    .addComponent(cbRole, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(29, Short.MAX_VALUE))
        );

        jbtAccList_Reset.setFont(new java.awt.Font("Segoe UI Light", 1, 14)); // NOI18N
        jbtAccList_Reset.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/image/016.png"))); // NOI18N
        jbtAccList_Reset.setText("Reset");
        jbtAccList_Reset.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtAccList_ResetActionPerformed(evt);
            }
        });

        jbtAccList_Submit.setFont(new java.awt.Font("Segoe UI Light", 1, 14)); // NOI18N
        jbtAccList_Submit.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/image/003.png"))); // NOI18N
        jbtAccList_Submit.setText("Submit");
        jbtAccList_Submit.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtAccList_SubmitActionPerformed(evt);
            }
        });

        jLabel2.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/image/029.png"))); // NOI18N

        javax.swing.GroupLayout jdAccList_InsertUpdateLayout = new javax.swing.GroupLayout(jdAccList_InsertUpdate.getContentPane());
        jdAccList_InsertUpdate.getContentPane().setLayout(jdAccList_InsertUpdateLayout);
        jdAccList_InsertUpdateLayout.setHorizontalGroup(
            jdAccList_InsertUpdateLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jdAccList_InsertUpdateLayout.createSequentialGroup()
                .addGroup(jdAccList_InsertUpdateLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(jdAccList_InsertUpdateLayout.createSequentialGroup()
                        .addGap(60, 60, 60)
                        .addComponent(jbtAccList_Submit)
                        .addGap(38, 38, 38)
                        .addComponent(jbtAccList_Reset, javax.swing.GroupLayout.PREFERRED_SIZE, 117, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(jdAccList_InsertUpdateLayout.createSequentialGroup()
                        .addGap(170, 170, 170)
                        .addComponent(jLabel2)))
                .addContainerGap(81, Short.MAX_VALUE))
            .addGroup(jdAccList_InsertUpdateLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGroup(jdAccList_InsertUpdateLayout.createSequentialGroup()
                    .addContainerGap()
                    .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
        );
        jdAccList_InsertUpdateLayout.setVerticalGroup(
            jdAccList_InsertUpdateLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(jdAccList_InsertUpdateLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel2)
                .addGap(176, 176, 176)
                .addGroup(jdAccList_InsertUpdateLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jbtAccList_Submit, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addComponent(jbtAccList_Reset, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addGap(33, 33, 33))
            .addGroup(jdAccList_InsertUpdateLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                .addGroup(jdAccList_InsertUpdateLayout.createSequentialGroup()
                    .addGap(92, 92, 92)
                    .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addContainerGap(97, Short.MAX_VALUE)))
        );

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        setTitle("Sale Invoice Management");
        setIconImage(new ImageIcon(getClass().getResource("/com/image/icon.png")).getImage());
        setResizable(false);

        jtbAccountList.setFont(new java.awt.Font("Segoe UI Light", 0, 14)); // NOI18N
        jtbAccountList.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "CustomerID", "CustomerName", "SalesInvoiceID", "DrugName", "UnitPrice", "Quantity", "Discount", "SubTotal", "ModeOfPayment", "Date"
            }
        ));
        jtbAccountList.setSelectionMode(javax.swing.ListSelectionModel.SINGLE_SELECTION);
        jScrollPane1.setViewportView(jtbAccountList);

        jbtAccountListInsert.setFont(new java.awt.Font("Segoe UI Light", 1, 14)); // NOI18N
        jbtAccountListInsert.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/image/026.png"))); // NOI18N
        jbtAccountListInsert.setText("Report");
        jbtAccountListInsert.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtAccountListInsertActionPerformed(evt);
            }
        });

        jbtAccountListUpdate.setFont(new java.awt.Font("Segoe UI Light", 1, 14)); // NOI18N
        jbtAccountListUpdate.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/image/027.png"))); // NOI18N
        jbtAccountListUpdate.setText("Update");
        jbtAccountListUpdate.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jbtAccountListUpdateActionPerformed(evt);
            }
        });

        jLabel1.setFont(new java.awt.Font("Segoe UI Light", 1, 24)); // NOI18N
        jLabel1.setForeground(new java.awt.Color(255, 0, 0));
        jLabel1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/image/009.png"))); // NOI18N
        jLabel1.setText("Sale Invoice Management");

        jtfAccList_Search.setFont(new java.awt.Font("Segoe UI Light", 0, 14)); // NOI18N
        jtfAccList_Search.setToolTipText("Search by Name");
        jtfAccList_Search.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jtfAccList_SearchActionPerformed(evt);
            }
        });
        jtfAccList_Search.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyPressed(java.awt.event.KeyEvent evt) {
                jtfAccList_SearchKeyPressed(evt);
            }
        });

        jlblAccList_Username1.setFont(new java.awt.Font("Segoe UI Light", 1, 14)); // NOI18N
        jlblAccList_Username1.setForeground(new java.awt.Color(51, 0, 255));
        jlblAccList_Username1.setIcon(new javax.swing.ImageIcon(getClass().getResource("/com/image/057.png"))); // NOI18N

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(jScrollPane1, javax.swing.GroupLayout.DEFAULT_SIZE, 850, Short.MAX_VALUE)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addGap(0, 0, Short.MAX_VALUE)
                .addComponent(jlblAccList_Username1)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jtfAccList_Search, javax.swing.GroupLayout.PREFERRED_SIZE, 307, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(16, 16, 16))
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(jLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 362, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(242, 242, 242))
            .addGroup(layout.createSequentialGroup()
                .addGap(292, 292, 292)
                .addComponent(jbtAccountListInsert)
                .addGap(18, 18, 18)
                .addComponent(jbtAccountListUpdate)
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel1)
                .addGap(18, 18, 18)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.CENTER)
                    .addComponent(jtfAccList_Search, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.PREFERRED_SIZE, 40, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jlblAccList_Username1))
                .addGap(18, 18, 18)
                .addComponent(jScrollPane1, javax.swing.GroupLayout.PREFERRED_SIZE, 261, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(18, 18, 18)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jbtAccountListInsert)
                    .addComponent(jbtAccountListUpdate))
                .addGap(13, 13, 13))
        );

        pack();
    }// </editor-fold>//GEN-END:initComponents

    /* Reset button */
    private void jbtAccList_ResetActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtAccList_ResetActionPerformed
        

    }//GEN-LAST:event_jbtAccList_ResetActionPerformed

    /* Submit button */
    private void jbtAccList_SubmitActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtAccList_SubmitActionPerformed
        String mode = String.valueOf(cbRole.getSelectedItem());
       
        try {
            if (SaleInvoiceManager.update(mode,Integer.parseInt(jlblAccList_Email3.getText()))) {
                JOptionPane.showMessageDialog(null, "Update successfull", "Message", JOptionPane.INFORMATION_MESSAGE);
                loadData();
            }
        } catch (Exception ex) {
            
        }
    }//GEN-LAST:event_jbtAccList_SubmitActionPerformed

    /* Update data */
    private void jbtAccountListUpdateActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtAccountListUpdateActionPerformed
        
        if (jtbAccountList.getSelectedRowCount() == 1) {
            jdAccList_InsertUpdate.setVisible(true);
            jdAccList_InsertUpdate.pack();
            jdAccList_InsertUpdate.setLocationRelativeTo(null);
            getID = Integer.parseInt(String.valueOf(tableModel.getValueAt(jtbAccountList.getSelectedRow(), 2)));
            jlblAccList_Email3.setText(getID + "");
//            System.out.println(String.valueOf(tableModel.getValueAt(jtbAccountList.getSelectedRow(), 8)));
            cbRole.setSelectedItem(String.valueOf(tableModel.getValueAt(jtbAccountList.getSelectedRow(), 8)));
            
        } else {
            JOptionPane.showMessageDialog(null, "Please choose a record to update", "Message", JOptionPane.INFORMATION_MESSAGE);
        }
    }//GEN-LAST:event_jbtAccountListUpdateActionPerformed

    /*
     * Searching data
     */
    private void jtfAccList_SearchKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_jtfAccList_SearchKeyPressed
        jtfAccList_Search.getDocument().addDocumentListener(
                new DocumentListener() {
                    @Override
                    public void changedUpdate(DocumentEvent e) {
                        newFilter();
                    }
                    
                    @Override
                    public void insertUpdate(DocumentEvent e) {
                        newFilter();
                    }
                    
                    @Override
                    public void removeUpdate(DocumentEvent e) {
                        newFilter();
                    }
                    
                    private void newFilter() {
                        TableRowSorter sorter = new TableRowSorter<>(tableModel);
                        jtbAccountList.setRowSorter(sorter);
                        // Fillter data by cloumn = 1
                        RowFilter<DefaultTableModel, Object> rowFilter = RowFilter.regexFilter(jtfAccList_Search.getText(), 1);
                        sorter.setRowFilter(rowFilter);
                    }
                });
    }//GEN-LAST:event_jtfAccList_SearchKeyPressed

    private void jtfAccList_SearchActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jtfAccList_SearchActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_jtfAccList_SearchActionPerformed

    /* Insert data */
    private void jbtAccountListInsertActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jbtAccountListInsertActionPerformed
        new Report().setVisible(true);
    }//GEN-LAST:event_jbtAccountListInsertActionPerformed

    /* Load data to table */
    private void loadData() {
        tableModel = (DefaultTableModel) jtbAccountList.getModel();
        tableModel.setRowCount(0);
        try {

            // Fill all record from users table
            ResultSet resultSet = SaleInvoiceManager.displayAllRows();
            while (resultSet.next()) {
                Vector vector = new Vector();
                vector.add(String.valueOf(resultSet.getInt(1)).trim());
                vector.add(resultSet.getString(2).trim());
                vector.add(String.valueOf(resultSet.getInt(3)).trim());
                vector.add(resultSet.getString(4).trim());
                vector.add(String.valueOf(resultSet.getDouble(5)));
                vector.add(String.valueOf(resultSet.getInt(6)));
                vector.add(String.valueOf(resultSet.getDouble(7)));
                vector.add(String.valueOf(resultSet.getDouble(8)));
                vector.add(resultSet.getString(9).trim());
                vector.add(String.valueOf(resultSet.getDate(10)));
                tableModel.addRow(vector);
                
            }

            // Fill data into combobox cbRole
            if (cbRole.getItemCount() == 0) {
                ResultSet rsRoles = UserManager.getRoles();
                while (rsRoles.next()) {
                    cbRole.addItem(new ComboItem(rsRoles.getString(2), String.valueOf(rsRoles.getInt(1)).trim()));
                }
            }

//            cbRole.addItem(new ComboItem("Visible String 1", "Value 1"));
//
//            Object item = cbRole.getSelectedItem();
//            String str = ((ComboItem) item).getValue();
        } catch (SQLException ex) {
            System.out.println(ex.getMessage());
        }
    }
    
    class ComboItem {
        
        private String key;
        private String value;
        
        public ComboItem(String key, String value) {
            this.key = key;
            this.value = value;
        }
        
        @Override
        public String toString() {
            return key;
        }
        
        public String getKey() {
            return key;
        }
        
        public String getValue() {
            return value;
        }
    }

    /* Clearn form */
    private void clearForm() {
//        jtfAccList_Username.setText(null);
//        jtfAccList_Password.setText(null);
//        jtfAccList_Email.setText(null);
//        jtfAccList_Address.setText(null);
//        cbMonth.setSelectedIndex(0);
//        cbDay.setSelectedIndex(0);
//        cbYear.setSelectedIndex(0);
    }
    
    public static void main(String args[]) {
        /* Set the Nimbus look and feel */
        //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) ">
        /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel.
         * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html 
         */
        try {
            for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) {
                if ("Nimbus".equals(info.getName())) {
                    javax.swing.UIManager.setLookAndFeel(info.getClassName());
                    break;
                }
            }
        } catch (ClassNotFoundException ex) {
            java.util.logging.Logger.getLogger(SaleInvoiceList.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (InstantiationException ex) {
            java.util.logging.Logger.getLogger(SaleInvoiceList.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (IllegalAccessException ex) {
            java.util.logging.Logger.getLogger(SaleInvoiceList.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        } catch (javax.swing.UnsupportedLookAndFeelException ex) {
            java.util.logging.Logger.getLogger(SaleInvoiceList.class.getName()).log(java.util.logging.Level.SEVERE, null, ex);
        }
        //</editor-fold>

        /* Create and display the form */
        java.awt.EventQueue.invokeLater(new Runnable() {
            
            public void run() {
                new SaleInvoiceList().setVisible(true);
            }
        });
    }
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JComboBox cbRole;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JPanel jPanel1;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JButton jbtAccList_Reset;
    private javax.swing.JButton jbtAccList_Submit;
    private javax.swing.JButton jbtAccountListInsert;
    private javax.swing.JButton jbtAccountListUpdate;
    private javax.swing.JDialog jdAccList_InsertUpdate;
    private javax.swing.JLabel jlblAccList_Email1;
    private javax.swing.JLabel jlblAccList_Email2;
    private javax.swing.JLabel jlblAccList_Email3;
    private javax.swing.JLabel jlblAccList_Username1;
    private javax.swing.JTable jtbAccountList;
    private javax.swing.JTextField jtfAccList_Search;
    // End of variables declaration//GEN-END:variables
    private String flag = "";
    DefaultTableModel tableModel;
}
